# Packager: Justin Davis (juster) <jrcd83@gmail.com>
# $Id: PKGBUILD 165162 2012-08-11 22:02:59Z eric $

pkgname=perl-common-sense
pkgver=3.6
pkgrel=1
pkgdesc='save a tree AND a kitten, use common::sense!'
arch=(any)
license=(PerlArtistic GPL)
options=(!emptydirs)
depends=(perl)
url=http://search.cpan.org/dist/common-sense
source=("http://search.cpan.org/CPAN/authors/id/M/ML/MLEHMANN/common-sense-$pkgver.tar.gz")
md5sums=('9332e9fe85b0bce8c287a0429d164809')
_dir="$srcdir/common-sense-$pkgver"

build()
(
  cd "$_dir"
  export PERL_MM_USE_DEFAULT=1 PERL_AUTOINSTALL=--skipdeps
  unset PERL5LIB PERL_MM_OPT
  /usr/bin/perl Makefile.PL
  make
)

check()
(
  cd "$_dir"
  export PERL_MM_USE_DEFAULT=1
  unset PERL5LIB
  make test
)

package()
(
  cd "$_dir"
  make install INSTALLDIRS=vendor DESTDIR="$pkgdir"
)

# Local Variables:
# mode: shell-script
# sh-basic-offset: 2
# End:
# vim:set ts=2 sw=2 et:
